package com.cmc.cloud.cmclink.doc.vo.blnoscnvo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

import java.util.Objects;

/**
 * @author 周贤
 * @date 2025/8/18
 */
@AllArgsConstructor
@NoArgsConstructor
@Getter
@Setter
@ToString
public class BlnoScnSameVO {
    @Schema(description = "相关方类型")
    private String partyTypeCode;

    @Schema(description = "公司客商主数据代码")
    private String csmCode;

    @Schema(description = "企业唯一识别码 前缀")
    private String uniqueIdentifierPre;

    @Schema(description = "企业唯一识别码 后缀")
    private String uniqueIdentifierFix;

    @Schema(description = "公司名称", example = "李四")
    private String companyName;

    @Schema(description = "公司地址")
    private String companyAddress;

    @Schema(description = "地址打印标识")
    private Boolean addressPrintFlag;

    @Schema(description = "国家代码")
    private String countryCode;

    @Schema(description = "电话")
    private String telephone;

    @Schema(description = "电话打印标识")
    private Boolean telephonePrintFlag;

    @Schema(description = "邮箱")
    private String email;

    private Boolean emailPrintFlag;

    @Schema(description = "传真")
    private String fax;

    @Schema(description = "传真打印标识")
    private Boolean faxPrintFlag;

    @Schema(description = "城市")
    private String city;

    @Schema(description = "城市代码")
    private String cityCode;

    @Schema(description = "省份")
    private String province;

    @Schema(description = "省份代码")
    private String provinceCode;

    @Schema(description = "AEO（经认证的经营者）")
    private String aeo;

    @Schema(description = "邮政编码")
    private String zipCode;

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        BlnoScnSameVO that = (BlnoScnSameVO) o;
        return Objects.equals(partyTypeCode, that.partyTypeCode) &&
                Objects.equals(csmCode, that.csmCode) &&
                Objects.equals(uniqueIdentifierPre, that.uniqueIdentifierPre) &&
                Objects.equals(uniqueIdentifierFix, that.uniqueIdentifierFix) &&
                Objects.equals(companyName, that.companyName) &&
                Objects.equals(companyAddress, that.companyAddress) &&
                Objects.equals(addressPrintFlag, that.addressPrintFlag) &&
                Objects.equals(countryCode, that.countryCode) &&
                Objects.equals(telephone, that.telephone) &&
                Objects.equals(telephonePrintFlag, that.telephonePrintFlag) &&
                Objects.equals(email, that.email) &&
                Objects.equals(emailPrintFlag, that.emailPrintFlag) &&
                Objects.equals(fax, that.fax) &&
                Objects.equals(faxPrintFlag, that.faxPrintFlag) &&
                Objects.equals(city, that.city) &&
                Objects.equals(cityCode, that.cityCode) &&
                Objects.equals(province, that.province) &&
                Objects.equals(provinceCode, that.provinceCode) &&
                Objects.equals(aeo, that.aeo) &&
                Objects.equals(zipCode, that.zipCode);
    }

    @Override
    public int hashCode() {
        return Objects.hash(partyTypeCode, csmCode, uniqueIdentifierPre, uniqueIdentifierFix, companyName, companyAddress, addressPrintFlag, countryCode, telephone, telephonePrintFlag, email, emailPrintFlag, fax, faxPrintFlag, city, cityCode, province, provinceCode, aeo, zipCode);
    }
}
